import {defineStore} from "pinia";
import {ref} from "vue";


export const useStudentStores = defineStore("studentStore", () => {
    // 分数列表
    const scores = ref([
    ])
    // 学生的课程
    const courses = ref([])
    const sc = ref([])

    function studentInit(data){
        console.log(data)
        courses.value = data.courses
    }

    function resetStuData(){
        sc.value = []
        courses.value = []
        sc.value = []
    }
    return { scores, courses, sc, studentInit, resetStuData }
})